home *** CD-ROM | disk | FTP | other *** search
- 9/5/94
-
- PARSEDEM.MAK - A labor day project assembled from some good
- codestuff which I have found useful.
-
- By Paul W. Reynolds, CIS 71011,2040
- Internet Paul.Reynolds@Channel1.Com
- (note - I check in on CIS much more frequently
- than I do on Channel1)
-
-
- Information on Parse demo project.
-
- This project demonstrates routines can be used to effectively
- parse a string into its elements. They can be used to obtain
- the word count and linecount in a textbox. A single or
- variable length delimiter may be used. For small amounts of text
- are plenty fast but they bog down with large amounts of text.
- The 32K limit is also a pain. Nonetheless for many situations
- they are useful (parsing command-line paramters, tag values,
- INI file values, etc.)
-
-
- No special VBX's or DLL's required except for the VB
- runtime library VBRUN300.DLL and SPIN.VBX (included).
-
- To run the program, copy all the files into a common directory,
- and run the program from that directory.
-
-
- File List:
-
- PARSE.BAS - Contains routines used to parse and process strings
- and text. Explanations and information are given above each function
- routine, and code is heavily commented here and elsewhere
- (as is my convention). A few Global Constants are declared here.
-
- MDELIM.FRM (frmMultiDelim) - This is a second form which appears
- when the 'Multiple Char. Delim Test' command button is executed
- from frmParse. This part of the demonstration shows how the
- routines in PARSE.BAS can be used for parsing small strings
- and finding strings within strings.
-
- PARSE.FRM (frmParse) - This is the first form that appears in the project.
- (NOTE: the 'startup form' for the project is Sub Main, located in
- PARSE.BAS). The code required to execute the parsing of a text
- field into lines and words is called here.
-
- SELFILE.FRM (frmSelFile) - This form loads when the 'Select File'
- command button is executed. This is where you select a text file
- to parse.
-
- PARSEME.TXT - This readme file.
-
- BASIC.TXT - A short text file I used fro testing the code.
-
- PARSEDEM.MAK
-
- SPIN.VBX
-
-
-
- Other Comments:
-
- Naming conventions used:
-
- * Variables - Type-declaration characters used for giving variable
- type information. I also use prefixes for module and global
- scope (this project has no module or global variables).
-
- * Standard control prefixes are used similar to those recommended
- by MS Consulting Services.
-
-
-
-
- This project is Public Domain - I hope that it is useful, but
- I hold no responsibility for any damages resulting from the
- use and/or misuse of the code contained herein.
-
- My apologies to the artistically inclined for my ugly interface.
- However, hopefully, the code you will find useful.
-
-